﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Runtime.Serialization;

namespace Model
{
    [DataContract]
    public class Event
    {
        [DataMember]
        private int id;
        [DataMember]
        private DateTime time;
        [DataMember]
        private Movie movie;
        [DataMember]
        private Cinema cinema;
        [DataMember]
        private double price;
        [DataMember]
        private int seatsBooked;
        [DataMember]
        private int seatsSold;

        public Event(int id, DateTime time, Movie movie, Cinema cinema, double price, int seatsBooked, int seatsSold)
        {
            Id = id;
            Time = time;
            Movie = movie;
            Cinema = cinema;
            Price = price;
            SeatsBooked = seatsBooked;
            SeatsSold = seatsSold;
        }

        public Event(DateTime time, Movie movie, Cinema cinema, double price, int seatsBooked, int seatsSold)
        {
            Time = time;
            Movie = movie;
            Cinema = cinema;
            Price = price;
            SeatsBooked = seatsBooked;
            SeatsSold = seatsSold;
        }

        public Event()
        {
            
        }

        [DataMember]
        public int SeatsSold
        {
            get { return seatsSold; }
            set { seatsSold = value; }
        }

        [DataMember]
        public int SeatsBooked
        {
            get { return seatsBooked; }
            set { seatsBooked = value; }
        }

        [DataMember]
        public double Price
        {
            get { return price; }
            set { price = value; }
        }

        [DataMember]
        public int Id
        {
            get { return this.id; }
            set { this.id = value; }
        }

        [DataMember]
        public DateTime Time
        {
            get { return this.time; }
            set { this.time = value; }
        }

        [DataMember]
        public Movie Movie
        {
            get { return this.movie; }
            set { this.movie = value; }
        }

        [DataMember]
        public Cinema Cinema
        {
            get { return this.cinema; }
            set { this.cinema = value; }
        }

    }
}
